package ast;

import java.util.ArrayList;

public class Call extends Process {

	private String name;
	private ArrayList<Expression> arguments;
	
	public Call(String nm, ArrayList<Expression> args)
	{
		name = nm;
		arguments = args;
	}
	
	public ArrayList<Expression> getArguments()
	{
		return arguments;
	}
	
	public String getName() {
		return name;
	}

	public String toString(int indent)
	{
		String res = "";
		res += name + "(";
		for (int i = 0; i < arguments.size(); i++) {
			res += arguments.get(i);
			if (i < arguments.size() - 1)
				res += ", ";
		}
		res += ")";
		
		return res;
	}
}
